/*    */ package com.zimbra.cs.session;
/*    */ 
/*    */ import com.zimbra.cs.mailbox.MailItem.Type;
/*    */ import com.zimbra.cs.redolog.CommitId;
/*    */ import com.zimbra.cs.redolog.RedoCommitCallback;
/*    */ import java.util.Set;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ public class AllAccountsRedoCommitCallback
/*    */   implements RedoCommitCallback
/*    */ {
/*    */   private final String accountId;
/*    */   private final Set<MailItem.Type> changeTypes;
/*    */   
/*    */   private AllAccountsRedoCommitCallback(String accountId, Set<MailItem.Type> types)
/*    */   {
/* 30 */     this.accountId = accountId;
/* 31 */     this.changeTypes = types;
/*    */   }
/*    */   
/*    */   public void callback(CommitId cid)
/*    */   {
/* 36 */     AllAccountsWaitSet.mailboxChangeCommitted(cid.encodeToString(), this.accountId, this.changeTypes);
/*    */   }
/*    */   
/*    */   public static final AllAccountsRedoCommitCallback getRedoCallbackIfNecessary(String accountId, Set<MailItem.Type> types)
/*    */   {
/* 41 */     if (AllAccountsWaitSet.isCallbackNecessary(types)) {
/* 42 */       return new AllAccountsRedoCommitCallback(accountId, types);
/*    */     }
/* 44 */     return null;
/*    */   }
/*    */ }


/* Location:              /home/mint/zimbrastore.jar!/com/zimbra/cs/session/AllAccountsRedoCommitCallback.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       0.7.1
 */